package com.gxa.Task;

import com.gxa.service.DailyAgentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.util.Date;

@Component
public class MyTask {
    @Autowired
    DailyAgentService dailyAgentService;

    @Scheduled(cron = "0 0 0 * * ?")
    public void dailyAgent(){
        dailyAgentService.truncateDailyAgent();
    }



}
